package com.llh.uua.service

import org.ktorm.database.Database
import org.ktorm.entity.EntitySequence
import org.ktorm.entity.sequenceOf
import org.ktorm.schema.BaseTable

/**
 *
 *
 * Created At 2021/3/17 21:50
 * @author llh
 */
abstract class BaseService<E : Any, T : BaseTable<E>>(private val database: Database, private val mapper: T) {

    fun sequence(): EntitySequence<E, T> {
        return database.sequenceOf(mapper)
    }

}